package com.ruoyi.db.sms.domain;

import lombok.Data;
import lombok.EqualsAndHashCode;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import com.ruoyi.framework.aspectj.lang.annotation.Excel;
import com.ruoyi.framework.web.domain.BaseEntity;
import javax.validation.constraints.Size;
import javax.validation.constraints.NotBlank;
import java.util.Date;

/**
 * 首页广告对象 sms_advertise
 *
 * @author yfy
 * @date 2020-04-21
 */

@ApiModel("首页广告实体类")
@Data
@EqualsAndHashCode(callSuper=true)
public class SmsAdvertise extends BaseEntity
{
    private static final long serialVersionUID = 1L;

    @ApiModelProperty("广告编号")
    private Long id;

    @ApiModelProperty("广告标题")
    @Excel(name = "广告标题")
    @NotBlank(message = "广告标题不能为空")
    @Size(min = 0, max = 63, message = "广告标题长度不能超过63个字符")
    private String name;

    @ApiModelProperty("广告链接地址")
    @Excel(name = "广告链接地址")
    @Size(min = 0, max = 255, message = "广告链接地址长度不能超过255个字符")
    private String link;

    @ApiModelProperty("广告宣传图片")
    @Excel(name = "广告宣传图片")
    @NotBlank(message = "广告宣传图片不能为空")
    @Size(min = 0, max = 255, message = "广告宣传图片长度不能超过255个字符")
    private String url;

    @ApiModelProperty("广告位置（1首页 0非首页）")
    @Excel(name = "广告位置", readConverterExp = "1=首页,0=非首页")
    private Integer position;

    @ApiModelProperty("活动内容")
    @Excel(name = "活动内容")
    @Size(min = 0, max = 255, message = "活动内容长度不能超过255个字符")
    private String content;

    @ApiModelProperty("广告开始时间")
    private Date startTime;

    @ApiModelProperty("广告结束时间")
    private Date endTime;

    @ApiModelProperty("是否启动")
    @Excel(name = "是否启动")
    private Boolean enabled;

    @ApiModelProperty("创建时间")
    private Date addTime;

    @ApiModelProperty("逻辑删除")
    private Integer deleted;

}
